<?php error_reporting(E_ALL^E_NOTICE^E_WARNING^E_DEPRECATED);?>
<!-- AUI Framework -->
<!DOCTYPE html>
    <html>
    <head>

        <meta charset="utf-8">
        <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
        <title>淘宝账目管理</title>
        <meta name="description" content="">
        <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no">

        <!-- Favicons -->

        <link rel="apple-touch-icon-precomposed" sizes="144x144" href="assets/images/icons/apple-touch-icon-144-precomposed.png">
        <link rel="apple-touch-icon-precomposed" sizes="114x114" href="assets/images/icons/apple-touch-icon-114-precomposed.png">
        <link rel="apple-touch-icon-precomposed" sizes="72x72" href="assets/images/icons/apple-touch-icon-72-precomposed.png">
        <link rel="apple-touch-icon-precomposed" href="assets/images/icons/apple-touch-icon-57-precomposed.png">
        <link rel="shortcut icon" href="assets/images/icons/favicon.png">

        <!--[if lt IE 9]>
          <script src="assets/js/minified/core/html5shiv.min.js"></script>
          <script src="assets/js/minified/core/respond.min.js"></script>
        <![endif]-->

        <!--[if lt IE 7]>
        <link rel="stylesheet" type="text/css" href="assets/css/minified/icons-ie7.min.css">
        <![endif]-->

        <!-- AgileUI CSS Core -->

        <link rel="stylesheet" type="text/css" href="assets/css/minified/aui-production.min.css">

        <!-- Theme UI -->

        <link id="layout-theme" rel="stylesheet" type="text/css" href="assets/themes/minified/agileui/color-schemes/layouts/default.min.css">
        <link id="elements-theme" rel="stylesheet" type="text/css" href="assets/themes/minified/agileui/color-schemes/elements/default.min.css">

        <!-- AgileUI Responsive -->

        <link rel="stylesheet" type="text/css" href="assets/themes/minified/agileui/responsive.min.css">

        <!-- AgileUI JS -->

      

     
     

    </head>

    <body >
       
                    

    <!-- AgileUI CSS -->

    <link rel="stylesheet" type="text/css" href="assets/css/minified/aui-production.min.css">

    <!-- Theme UI -->

    <link id="layout-theme" rel="stylesheet" type="text/css" href="assets/themes/minified/agileui/color-schemes/layouts/default.min.css">
    <link id="elements-theme" rel="stylesheet" type="text/css" href="assets/themes/minified/agileui/color-schemes/elements/default.min.css">

    <link rel="stylesheet" type="text/css" href="assets/themes/minified/agileui/responsive.min.css">

    <!-- AgileUI JS -->

     <script type="text/javascript" src="assets/js/aui-production.js"></script>
		 <script type="text/javascript" src="assets/js/aui-demo.js"></script>



    <!-- AgileUI CSS -->

    <link rel="stylesheet" type="text/css" href="assets/css/minified/aui-helpers.min.css">

    <!-- AgileUI CSS Widgets -->

    <link rel="stylesheet" type="text/css" href="assets/css/minified/elements/buttons.min.css">
    <link rel="stylesheet" type="text/css" href="assets/css/minified/widgets/datepicker.min.css">
    <link rel="stylesheet" type="text/css" href="assets/css/minified/widgets/tabs.min.css">
    <link rel="stylesheet" type="text/css" href="assets/css/minified/widgets/dropdown.min.css">
    <link rel="stylesheet" type="text/css" href="assets/css/minified/widgets/tooltip.min.css">

    <!-- Theme UI -->

    <link id="layout-theme" rel="stylesheet" type="text/css" href="assets/themes/minified/agileui/color-schemes/layouts/default.min.css">
    <link id="elements-theme" rel="stylesheet" type="text/css" href="assets/themes/minified/agileui/color-schemes/elements/default.min.css">

    <link rel="stylesheet" type="text/css" href="assets/themes/minified/agileui/responsive.min.css">

    <!-- AgileUI JS (Uncomment the next line) -->

    <!-- <script type="text/javascript" src="assets/js/minified/aui-core.min.js"></script> -->

    <!-- AgileUI JS Widgets -->
<a href="index.php" class="btn medium primary-bg" title="">
            <span class="button-content">账目</span>
        </a>
		<a href="jinhuo.php" class="btn medium primary-bg" title="">
            <span class="button-content">进货</span>
        </a>
   <?php
	$conn=mysql_connect('localhost','root','');

	mysql_query("set names 'utf8'"); //数据库输出编码 应该与你的数据库编码保持一致.南昌网站建设公司百恒网络PHP工程师建议用UTF-8 国际标准编码.
	 
	mysql_select_db('taobao'); //打开数据库
	 
	 function getn($name){
	 	//echo ("select chengben from chanpin where name='$name'");
	 	$result = mysql_query("select pinming from chanpin where name='$name'");
		$row = mysql_fetch_array($result); 
		$pinming = $row['pinming'];
		return $pinming;
	 }
	
  
  if($_SERVER['REQUEST_METHOD'] == 'POST' and $_POST['chaxun']!="yes"){
  		
		$shijian = $_POST['shijian'];
		$jine =0;
		$huopin = '';
		$chengben = 0;
		$beizhu = $_POST['beizhu'];
		
		if($_POST['fengqin']!=''){
			$huopin = $huopin.getn('fengqin')."x".$_POST['fengqin']."斤/".$_POST['fengqin1']."元每斤=>共计：".(float)($_POST['fengqin'])*(float)($_POST['fengqin1'])."元<br>";
			$chengben = $chengben+(float)($_POST['fengqin'])*(float)($_POST['fengqin1']);
		}
		if($_POST['youyuzai']!=''){
			$huopin = $huopin.getn('youyuzai')."x".$_POST['youyuzai']."斤/".$_POST['youyuzai1']."元每斤=>共计：".(float)($_POST['youyuzai'])*(float)($_POST['youyuzai1'])."元<br>";
			$chengben = $chengben+(float)($_POST['youyuzai'])*(float)($_POST['youyuzai1']);
		}
		if($_POST['zupian']!=''){
			$huopin = $huopin.getn('zupian')."x".$_POST['zupian']."斤/".$_POST['zupian1']."元每斤=>共计：".(float)($_POST['zupian'])*(float)($_POST['zupian1'])."元<br>";
			$chengben = $chengben+(float)($_POST['zupian'])*(float)($_POST['zupian1']);
		}
		if($_POST['paojiao']!=''){
			$huopin = $huopin.getn('paojiao')."x".$_POST['paojiao']."斤/".$_POST['paojiao1']."元每斤=>共计：".(float)($_POST['paojiao'])*(float)($_POST['paojiao1'])."元<br>";
			$chengben = $chengben+(float)($_POST['paojiao'])*(float)($_POST['paojiao1']);
		}
		if($_POST['youyutou']!=''){
			$huopin = $huopin.getn('youyutou')."x".$_POST['youyutou']."斤/".$_POST['youyutou1']."元每斤=>共计：".(float)($_POST['youyutou'])*(float)($_POST['youyutou1'])."元<br>";
			$chengben = $chengben+(float)($_POST['youyutou'])*(float)($_POST['youyutou1']);
		}
		if($_POST['daiyu']!=''){
			$huopin = $huopin.getn('daiyu')."x".$_POST['daiyu']."斤/".$_POST['daiyu1']."元每斤=>共计：".(float)($_POST['daiyu'])*(float)($_POST['daiyu1'])."元<br>";
			$chengben = $chengben+(float)($_POST['daiyu'])*(float)($_POST['daiyu1']);
		}
			if($_POST['mabu']!=''){
			$huopin = $huopin.getn('mabu')."x".$_POST['mabu']."斤/".$_POST['mabu1']."元每斤=>共计：".(float)($_POST['mabu'])*(float)($_POST['mabu1'])."元<br>";
			$chengben = $chengben+(float)($_POST['mabu'])*(float)($_POST['mabu1']);
		}
		if($_POST['huanghua']!=''){
			$huopin = $huopin.getn('huanghua')."x".$_POST['huanghua']."斤/".$_POST['huanghua1']."元每斤=>共计：".(float)($_POST['huanghua'])*(float)($_POST['huanghua1'])."元<br>";
			$chengben = $chengben+(float)($_POST['huanghua'])*(float)($_POST['huanghua1']);
		}
		if($_POST['bayu']!=''){
			$huopin = $huopin.getn('bayu')."x".$_POST['bayu']."斤/".$_POST['bayu1']."元每斤=>共计：".(float)($_POST['bayu'])*(float)($_POST['bayu1'])."元<br>";
			$chengben = $chengben+(float)($_POST['bayu'])*(float)($_POST['bayu1']);
		}
		if($_POST['xia']!=''){
			$huopin = $huopin.getn('xia')."x".$_POST['xia']."斤/".$_POST['xia1']."元每斤=>共计：".(float)($_POST['xia'])*(float)($_POST['xia1'])."元<br>";
			$chengben = $chengben+(float)($_POST['xia'])*(float)($_POST['xia1']);
		}
		if($_POST['beiding']!=''){
			$huopin = $huopin.getn('beiding')."x".$_POST['beiding']."斤/".$_POST['beiding1']."元每斤=>共计：".(float)($_POST['beiding'])*(float)($_POST['beiding1'])."元<br>";
			$chengben = $chengben+(float)($_POST['beiding'])*(float)($_POST['beiding1']);
		}
		if($_POST['xiuxian']!=''){
			$huopin = $huopin.getn('xiuxian')."x".$_POST['xiuxian']."斤/".$_POST['xiuxian1']."元每斤=>共计：".(float)($_POST['xiuxian'])*(float)($_POST['xiuxian1'])."元<br>";
			$chengben = $chengben+(float)($_POST['xiuxian'])*(float)($_POST['xiuxian1']);
		}
		if($_POST['meiren']!=''){
			$huopin = $huopin.getn('meiren')."x".$_POST['meiren']."斤/".$_POST['meiren1']."元每斤=>共计：".(float)($_POST['meiren'])*(float)($_POST['meiren1'])."元<br>";
			$chengben = $chengben+(float)($_POST['meiren'])*(float)($_POST['meiren1']);
		}
		if($_POST['xiajiang']!=''){
			$huopin = $huopin.getn('xiajiang')."x".$_POST['xiajiang']."斤/".$_POST['xiajiang1']."元每斤=>共计：".(float)($_POST['xiajiang'])*(float)($_POST['xiajiang1'])."元<br>";
			$chengben = $chengben+(float)($_POST['xiajiang'])*(float)($_POST['xiajiang1']);
		}
		if($_POST['donggan']!=''){
			$huopin = $huopin.getn('donggan')."x".$_POST['donggan']."斤/".$_POST['donggan1']."元每斤=>共计：".(float)($_POST['donggan'])*(float)($_POST['donggan1'])."元<br>";
			$chengben = $chengben+(float)($_POST['donggan'])*(float)($_POST['donggan1']);
		}
		if($_POST['guofu']!=''){
			$huopin = $huopin.getn('guofu')."x".$_POST['guofu']."斤/".$_POST['guofu1']."元每斤=>共计：".(float)($_POST['guofu'])*(float)($_POST['guofu1'])."元<br>";
			$chengben = $chengben+(float)($_POST['guofu'])*(float)($_POST['guofu1']);
		}
		if($_POST['guogan']!=''){
			$huopin = $huopin.getn('guogan')."x".$_POST['guogan']."斤/".$_POST['guogan1']."元每斤=>共计：".(float)($_POST['guogan'])*(float)($_POST['guogan1'])."元<br>";
			$chengben = $chengben+(float)($_POST['guogan'])*(float)($_POST['guogan1']);
		}
		if($_POST['haizhetou']!=''){
			$huopin = $huopin.getn('haizhetou')."x".$_POST['haizhetou']."斤/".$_POST['haizhetou1']."元每斤=>共计：".(float)($_POST['haizhetou'])*(float)($_POST['haizhetou1'])."元<br>";
			$chengben = $chengben+(float)($_POST['haizhetou'])*(float)($_POST['haizhetou1']);
		}
		if($_POST['haishen2']!=''){
			$huopin = $huopin.getn('haishen2')."x".$_POST['haishen2']."斤/".$_POST['haishen21']."元每斤=>共计：".(float)($_POST['haishen2'])*(float)($_POST['haishen21'])."元<br>";
			$chengben = $chengben+(float)($_POST['haishen2'])*(float)($_POST['haishen21']);
		}
		if($_POST['haocai']!=''){
			$huopin = $huopin."耗材x".$_POST['haocai'];
			$chengben = $chengben+(float)($_POST['haocai']);
		}
		if($_POST['yunfei']!=''){
			$huopin = $huopin."运费".$_POST['yunfei'];
			$chengben = ($_POST['yunfei']);
		}
			
		
		
		
		//echo("insert into jinhuo values('0','$shijian','$huopin','$chengben','$beizhu')");
		//exit();
		mysql_query("insert into jinhuo values('0','$shijian','$huopin','$chengben','$beizhu')");
		echo("<script>alert('录入成功！');window.location.href='/jinhuo.php'</script>");
		exit();
	
  }
  else{
  
  }
   ?>



	<div class="example-box">
    <div class="example-code clearfix">

        <form action="/jinhuo.php" class="col-md-12 center-margin" method="post">
		
		 <div class="form-row">
                <div class="form-label col-md-2">
                    <label for="">
                        时间
                    </label>
                </div>
                <div class="form-input col-md-4">
                    <input class="datepicker no-shadow" name="shijian">
                </div>
				
            </div>
			
			 <div class="form-row">
                <div class="form-label col-md-2">
                    <label for="">
                       金额
                    </label>
                </div>
                <div class="form-input col-md-4">
                    <input  type="text" name="jine" id="">
                </div>
				
				
            </div>
			 <div class="form-row">
                <div class="form-label col-md-2">
                    <label for="">
                       
                    </label>
                </div>
                <div class="form-input col-md-1">
                  进货数量/斤
                </div>
				<div class="form-input col-md-1">
                   进货单价/斤
                </div>
				<div class="form-label col-md-2">
                    <label for="">
                       
                    </label>
                </div>
              <div class="form-input col-md-1">
                  进货数量/斤
                </div>
				<div class="form-input col-md-1">
                   进货单价/斤
                </div>
            </div>
			
			
		   <div class="form-row">
                <div class="form-label col-md-2">
                    <label for="">
                        软烤风琴鱿鱼（辣味、原味）
                    </label>
                </div>
                <div class="form-input col-md-1">
                    <input  type="text" name="fengqin" id="">
                </div>
				 <div class="form-input col-md-1">
                    <input  type="text" name="fengqin1" id="">
                </div>
				
				<div class="form-label col-md-2">
                    <label for="">
                        鱿鱼仔（辣味、原味）
                    </label>
                </div>
                <div class="form-input col-md-1">
                    <input  type="text" name="youyuzai" id="">
                </div>
				 <div class="form-input col-md-1">
                    <input  type="text" name="youyuzai1" id="">
                </div>
            </div>
			 <div class="form-row">
                <div class="form-label col-md-2">
                    <label for="">
                        软烤麻辣章鱼片（辣味、原味）
                    </label>
                </div>
                <div class="form-input col-md-1">
                    <input  type="text" name="zupian" id="">
                </div>
				 <div class="form-input col-md-1">
                    <input  type="text" name="zupian1" id="">
                </div>
				<div class="form-label col-md-2">
                    <label for="">
                       软烤泡椒章鱼片
                    </label>
                </div>
                <div class="form-input col-md-1">
                    <input  type="text" name="paojiao" id="">
                </div>
				 <div class="form-input col-md-1">
                    <input  type="text" name="paojiao1" id="">
                </div>
            </div>
			 <div class="form-row">
                <div class="form-label col-md-2">
                    <label for="">
                       软烤比管鱼（鱿鱼头）
                    </label>
                </div>
                <div class="form-input col-md-1">
                    <input  type="text" name="youyutou" id="">
                </div>
				 <div class="form-input col-md-1">
                    <input  type="text" name="youyutou1" id="">
                </div>
				<div class="form-label col-md-2">
                    <label for="">
                      软烤带鱼
                    </label>
                </div>
                <div class="form-input col-md-1">
                    <input  type="text" name="daiyu" id="">
                </div>
				 <div class="form-input col-md-1">
                    <input  type="text" name="daiyu1" id="">
                </div>
            </div>
			 <div class="form-row">
                <div class="form-label col-md-2">
                    <label for="">
                       软烤马步鱼
                    </label>
                </div>
                <div class="form-input col-md-1">
                    <input  type="text" name="mabu" id="">
                </div>
				  <div class="form-input col-md-1">
                    <input  type="text" name="mabu1" id="">
                </div>
				<div class="form-label col-md-2">
                    <label for="">
                      软烤黄花鱼
                    </label>
                </div>
                <div class="form-input col-md-1">
                    <input  type="text" name="huanghua" id="">
                </div>
				 <div class="form-input col-md-1">
                    <input  type="text" name="huanghua1" id="">
                </div>
            </div>
			 <div class="form-row">
                <div class="form-label col-md-2">
                    <label for="">
                       软烤鲅鱼
                    </label>
                </div>
                <div class="form-input col-md-1">
                    <input  type="text" name="bayu" id="">
                </div>
				   <div class="form-input col-md-1">
                    <input  type="text" name="bayu1" id="">
                </div>
				<div class="form-label col-md-2">
                    <label for="">
                        软烤大虾
                    </label>
                </div>
                <div class="form-input col-md-1">
                    <input  type="text" name="xia" id="">
                </div>
				 <div class="form-input col-md-1">
                    <input  type="text" name="xia1" id="">
                </div>
            </div>
			 <div class="form-row">
                <div class="form-label col-md-2">
                    <label for="">
                       软烤贝丁（不带豆）
                    </label>
                </div>
                <div class="form-input col-md-1">
                    <input  type="text" name="beiding" id="">
                </div>
				 <div class="form-input col-md-1">
                    <input  type="text" name="beiding1" id="">
                </div>
				<div class="form-label col-md-2">
                    <label for="">
                        休闲鱼
                    </label>
                </div>
                <div class="form-input col-md-1">
                    <input  type="text" name="xiuxian" id="">
                </div>
				 <div class="form-input col-md-1">
                    <input  type="text" name="xiuxian1" id="">
                </div>
            </div>
			 <div class="form-row">
                <div class="form-label col-md-2">
                    <label for="">
                        美人渔系列
                    </label>
                </div>
                <div class="form-input col-md-1">
                    <input  type="text" name="meiren" id="">
                </div>
				 <div class="form-input col-md-1">
                    <input  type="text" name="meiren1" id="">
                </div>
				<div class="form-label col-md-2">
                    <label for="">
                       虾酱  
                    </label>
                </div>
                <div class="form-input col-md-1">
                    <input  type="text" name="xiajiang" id="">
                </div>
				  <div class="form-input col-md-1">
                    <input  type="text" name="xiajiang1" id="">
                </div>
            </div>
			 <div class="form-row">
                <div class="form-label col-md-2">
                    <label for="">
                        冻干无花果
                    </label>
                </div>
                <div class="form-input col-md-1">
                    <input  type="text" name="donggan" id="">
                </div>
				  <div class="form-input col-md-1">
                    <input  type="text" name="donggan1" id="">
                </div>
				<div class="form-label col-md-2">
                    <label for="">
                        无花果果脯
                    </label>
                </div>
                <div class="form-input col-md-1">
                    <input  type="text" name="guofu" id="">
                </div>
				 <div class="form-input col-md-1">
                    <input  type="text" name="guofu1" id="">
                </div>
            </div>
             <div class="form-row">
                <div class="form-label col-md-2">
                    <label for="">
                        果干
                    </label>
                </div>
                <div class="form-input col-md-1">
                    <input  type="text" name="guogan" id="">
                </div>
				  <div class="form-input col-md-1">
                    <input  type="text" name="guogan1" id="">
                </div>
				<div class="form-label col-md-2">
                    <label for="">
                        海蜇头（袋装）
                    </label>
                </div>
                <div class="form-input col-md-1">
                    <input  type="text" name="haizhetou" id="">
                </div>
				 <div class="form-input col-md-1">
                    <input  type="text" name="haizhetou1" id="">
                </div>
            </div>
            <div class="form-row">
                <div class="form-label col-md-2">
                    <label for="">
                        吕福记海参
                    </label>
                </div>
                <div class="form-input col-md-1">
                    <input  type="text" name="haishen2" id="">
                </div>
				  <div class="form-input col-md-1">
                    <input  type="text" name="haishen21" id="">
                </div>
			
            </div>
			 <div class="form-row">
                <div class="form-label col-md-2">
                    <label for="">
                        耗材
                    </label>
                </div>
                <div class="form-input col-md-1">
                    <input  type="text" name="haocai" id="">
                </div>
				 
				
            </div>
             <div class="form-row">
                <div class="form-label col-md-2">
                    <label for="">
                        运费
                    </label>
                </div>
                <div class="form-input col-md-1">
                    <input  type="text" name="yunfei" id="">
                </div>
				 
				
            </div>
			
			 <div class="form-row">
              
				 <div class="form-label col-md-2">
                    <label for="">
                        备注
                    </label>
                </div>
                <div class="form-input col-md-4">
				<textarea name="beizhu" id="" class="large-textarea"></textarea>
                  
                </div>
				
            </div>
		
		
           
			
			

		   
<button class="btn primary-bg medium" style=" margin-left:1000px;">
            <span class="button-content" >录入</span>
        </button>
          

        </form>
	
		
		<div class="example-box">
    <div class="example-code">
     <div class="form-row" style=" width:100%">
     <form action="" method="post">	
     <input name="chaxun" type="hidden" value="yes">
                <div class="form-label col-md-1">
                    <label for="">
                        从:
                    </label>
                </div>
                <div class="form-input col-md-1">
                    <input class="datepicker no-shadow" name="kaishi" value="<?=$_POST['kaishi'];?>">
                </div>
				<div class="form-label col-md-1">
                    <label for="">
                     至：
                    </label>
                </div>
                <div class="form-input col-md-1">
                  <input class="datepicker no-shadow" name="jieshu" value="<?=$_POST['jieshu'];?>"> 
                </div>
                 <div class="form-label col-md-1">
                    <label for="">
                     只查看运费
                    </label>
                </div>
                <div class="form-input col-md-1">
                  <input name="leixing" type="radio" value="yunfei" <?php if($_POST['leixing']=="yunfei"){?> checked<?php }?>>
                </div>
                <div class="form-label col-md-1">
                    <label for="">
                     只查看耗材
                    </label>
                </div>
                <div class="form-input col-md-1">
                  <input name="leixing" type="radio" value="haocai" <?php if($_POST['leixing']=="haocai"){?> checked<?php }?>>
                </div>
                 <div class="form-label col-md-1">
                    <label for="">
                     只查看进货
                    </label>
                </div>
                <div class="form-input col-md-1">
                  <input name="leixing" type="radio" value="jinhuo" <?php if($_POST['leixing']=="jinhuo"){?> checked<?php }?>>
                </div>
            </div>
           
<button class="btn primary-bg medium" style=" margin-left:1000px;">
            <span class="button-content" >查询</span>
        </button>
    </form>
<h4>
<?php
$sql = "select count(*) as a,sum(jine) as b from   jinhuo where 1=1  ";
$sql2 = "select * from   jinhuo where 1=1";
$leixing = $_POST['leixing'];
$kaishi = $_POST['kaishi'];
$jieshu = $_POST['jieshu'];
if($_POST['kaishi']!="" and $_POST['jieshu']!=""){
	$sql = $sql." and date>='$kaishi' and date<='$jieshu'";
	$sql2 = $sql2." and date>='$kaishi' and date<='$jieshu' ";
	}

if($leixing=="haocai"){
	$sql = $sql." and huopin like '%耗材%'";
	$sql2 = $sql2." and huopin like '%耗材%'";
	}
if($leixing=="jinhuo"){
	$sql = $sql." and huopin not like '%耗材%' and huopin not like '%运费%'";
	$sql2 = $sql2." and huopin not  like '%耗材%' and huopin not like '%运费%'";
	}
if($leixing=="yunfei"){
	$sql = $sql." and huopin  like '%运费%'";
	$sql2 = $sql2." and huopin  like '%运费%'";
	}
$sql2 = $sql2." order by date desc ";
//echo $sql2;
$result = mysql_query($sql);
				$row = mysql_fetch_array($result)
				?>

    总计进货单数:   <?php echo $row['a'];?> 总计进货金额:<?php echo round($row['b'],2);?>

</h4>
        <table class="table table-striped text-center">
            <thead>
                <tr>
					 <th class="text-center">序号</th>
                    <th class="text-center">时间</th>
                    <th>货品</th>
					<th>金额</th>
                    <th class="text-center">备注</th>
                     <th class="text-center">编辑</th>
					
                </tr>
            </thead>
            <tbody>
			<?php
			$result = mysql_query($sql2);
			$i=1;
				while($row = mysql_fetch_array($result)) 			{
				?>
                <tr>
                    <td><?php echo $i;?></td>
					 <td><?php echo $row["date"];?></td>
					  <td><?php echo $row['huopin'];?></td>
					 <td><?php echo $row['jine'];?></td>
					  <td><?php echo $row['beizhu'];?></td>
                       <td><a href="del2.php?id=<?php echo $row['id'];?>" class="btn medium primary-bg"  title="">
            <span class="button-content">删除</span>
        </a></td>
					  
                    
                </tr>
            <?php
			$i=$i+1;
			}
			?>
            </tbody>
        </table>

    </div>
    
</div>

    </div>
    
</div>


    </body>
</html>

